<!DOCTYPE html>
<html>

	<head>
		<meta charset="utf-8">
		<title>index</title>
		<meta name="referrer" content="never" />
		<meta name="viewport" content="width=device-width, initial-scale=1,maximum-scale=1,user-scalable=no">
		<meta name="apple-mobile-web-app-capable" content="yes">
		<meta name="apple-mobile-web-app-status-bar-style" content="black">
		<link rel="stylesheet" href="../../../../css/mui.min.css">
		<link rel="stylesheet" href="../../static/components/components.css" />
		<link rel="stylesheet" href="../../static/css/common.css">
		<link rel="stylesheet" type="text/css" href="../../../../css/preview.css" />
		<link rel="stylesheet" type="text/css" href="../../../../css/mui.picker.min.css" />
		<link rel="stylesheet" type="text/css" href="../../../../css/mui.poppicker.css" />
		<link rel="stylesheet" type="text/css" href="../../../../css/mui.picker.css" />
		<style>
		.label1{
			width: 40vw;
		}
		#n-ipt{
			margin: 0;
			padding: 0;
			width: 40vw;
			height: 25px;
			line-height: 25px;
		}
		textarea{
		 width: 55vw;
			 height: 70px;
			 padding: 5px;
			 margin-left: 5px;
		}
		.top-line{
			width: 100%;
			box-sizing: border;
			padding:5px 19px;
			background-color: #fff;
			margin-bottom: 10px;
		}
			.mui-bar-nav ~ .mui-content .mui-pull-top-pocket{
				top:180px !important;
			}
			.label{
				width: 18vw;
				white-space: nowrap;
			}
			.add-label{
				width: 35vw;
			}
			.item-title{
			width: 20vw;
			}
			.list-head{
				width: 94vw;
				margin-left: 3vw;
				background-color: #fff;
				padding: 10px;
				margin-bottom: 10px;
			}
			.myheigth {
				height: 9vw;
			}
			.list button{
				margin: 0 !important;
				padding: 0 4vw !important;
			}
			.selsect-box{
				margin-left: 5px;
				width: 45vw;
				height: 30px;
				border: 1px solid #999;
				line-height: 30px;
				box-sizing: border-box;
				padding-left: 5px;
			}
			#left_ipt{
				width: 45vw;
				height: 25px;
				line-height: 25px;
				margin-bottom: 0;
				margin-left: 5px;
				padding: 0 5px;
				border: 1px solid #999;
			}
			#editTime{
				width: 22vw;
				height: 25px;
				line-height: 25px;
				margin-bottom: 0;
				margin-left: 5px;
				padding: 0 5px;
				border: 1px solid #999;
				font-size: 3vw;
			}
			.l_content{
				max-width: 20vw;
				overflow: hidden;
				text-overflow: ellipsis;
				white-space: nowrap;
			}
		</style>
	</head>
 
	<body>

		<header class="mui-bar mui-bar-nav mui-bar-nav-bg">
			<a class="mui-action-back mui-icon mui-icon-left-nav mui-pull-left"></a>
			<h1 id="title" class="mui-title">停机记录-光伏</h1>
		</header>
		<div class="mui-content" id="content" v-cloak>
			<div class="top">
					<div class="search-model" style="width: 75vw;">
						<div class="mui-input-row mui-search">
							<input v-model="keyWords" @input="onChange" type="search"  class="mui-input-clear" style="background-color: #fff;" placeholder="请输入关键字等">
						</div>
					</div>
					<div class="top-textall">
						<span  @click="changeStatus(1)" v-if="status == '0'">待确认</span>
						<span  @click="changeStatus(0)" v-if="status == '1'">已确认</span>
					</div>
				
			</div>
			<div style="position: sticky;top: 45px;z-index: 11;" class="flex-between list-head">
				<div class="flex-row" style="font-weight: bold;">
					<div class="icon"></div>
					列表
				</div>
				<button v-if="status == 0" @tap="showAddform = true;islook = false;isEdit = false" class="submit_btn" style="	margin: 0 !important;padding: 0 4vw !important;">新增</button>
			</div>
			<div id="scroll">
				<div class="list" id="list">
					<div v-for="(item,index) in list" :key="index">
						<div>
							<div class="flex-between">
								<div>
									<div class="flex-row">
										<div class="flex-row">
											<span style="white-space: nowrap;">区域:</span>
											<span class="l_content">{{item.areaCompanyName}}</span>
										</div>
										<div class="flex-row" style="margin-left: 20px;">
											<span class="label">逆变器编号:</span>
											<span class="l_content">{{item.deviceCode}}</span>
										</div>
									</div>
									<div class="flex-row">
										<div class="flex-row">
											<span style="white-space: nowrap;">编辑人:</span>
											<span class="l_content">{{item.lastEditName}}</span>
										</div>
										<div class="flex-row" style="margin-left: 20px;">
											<span class="label">编辑时间:</span>
											<span class="l_content">{{item.lastEditTime | times}}</span>
										</div>
									</div>
								</div>
								<div>
									<button v-if="status == 0" @tap="confirm(item)" class="cancel_btn">确认</button>
									<button v-if="status == 0" style="margin-top: 5px !important;" @tap="edit(item)" class="cancel_btn">编辑</button>
									<button v-if="status == 1" @tap="look(item)" class="cancel_btn">查看</button>
								</div>
								
							</div>
						</div>
					</div>
				</div>
			</div>
			
			<!-- 新增 -->
			<div class="popup-bg" v-if="showAddform">				
				<div style="postion:relative;width:95vw;max-height: 80vh;padding: 15px 15px 0px;overflow: scroll;" class="add-box" @click@tap.stop="clickStop">
				  <div>	
					<div class="mt-10">
						基础信息
					</div>
					<div class="flex-row">
						<div class="flex-row">
							<div>最近编辑人</div>
							<input style="width: 20vw;" id="left_ipt" type="text" :value="lastEditName" :disabled="true" maxlength="60"/>
						</div>
						<div class="flex-row" style="margin-left: 5px;">
							<div>编辑时间</div>
							<div id="editTime"/>{{nowDate}}</div>
						</div>
					</div>
				  </div>	
				  <div>
					<div class="mt-10">
						逆变器信息
					</div>
						<div class="flex-row">
							<div class="left-title">&ensp;&ensp;所属区域</div>
							<div  class="selsect-box" @click="showCompany">{{companyName || '请选择区域'}}</div>
						</div>
						<div class="flex-row mt-10">
							<div class="left-title">&ensp;&ensp;&ensp;&ensp;&ensp;&ensp;场站</div>
							<div class="selsect-box" @click="showStationType">{{stationName || '请选择场站'}}</div>
						</div>
						<div class="flex-row mt-10">
							<div>逆变器编号</div>
							<input id="left_ipt" placeholder="请输入"  v-model="deviceCode" maxlength="60" id="editTime"/>
						</div>
						<div class="flex-row mt-10">
							<div>逆变器机型</div>
							<input id="left_ipt"  placeholder="请输入"   v-model="deviceType" maxlength="60" id="editTime"/>
						</div>
						<div class="flex-row mt-10">
							<div>&ensp;&ensp;&ensp;&ensp;&ensp;&ensp;期数</div>
							<input id="left_ipt"  placeholder="请输入"   v-model="projectNo" maxlength="60" id="editTime"/>
						</div>
					</div>
					<div class="mt-10">
						<div>停机信息</div>
						<div class="flex-row mt-10">
							<div>停机类型</div>
							<div class="selsect-box" @click="showShutType">{{shutDownTypename || '请选择停机类型'}}</div>
						</div>
						<div class="flex-row mt-10">
							<div>故障名称</div>
							<input id="left_ipt" placeholder="请输入"  v-model="faultName" maxlength="60" />
						</div>
						<div class="flex-row mt-10">
							<div>故障代码</div>
							<input id="left_ipt" placeholder="请输入"  v-model="faultCode" maxlength="60"/>
						</div>
						<div class="flex-row mt-10">
							<div>故障类别</div>
							<input id="left_ipt" placeholder="请输入"  v-model="faultType" maxlength="60"/>
						</div>
						<div class="flex-row mt-10">
							<div>所属系统</div>
							<div class="selsect-box" @click="showSystemType">{{systemTypename || '请选择故障所属系统'}}</div>
						</div>
						<div class="flex-row mt-10">
							<div>故障停机时间</div>
							<div class="selsect-box" id="shuttime" @click="chooseTime" style="width: 35vw;"/>{{shutdownTime || '请选择时间'}}</div>
						</div>
						<div class="flex-row mt-10">
							<div>开始处理时间</div>
							<div class="selsect-box" id="dealbegtime" @click="choosebegTime" style="width: 35vw;"/>{{dealBegTime || '请选择时间'}}</div>
						</div>
						<div class="flex-row mt-10">
							<div>处理结束时间</div>
							<div class="selsect-box" id="dealendtime" @click="chooseendTime" style="width: 35vw;"/>{{dealEndTime || '请选择时间'}}</div>
						</div>
						<div class="flex-row mt-10">
							<div>维修工时</div>
							<input id="left_ipt" placeholder="请输入维修工时"  v-model="repairCost" maxlength="60" />
						</div>
						<div class="flex-row mt-10">
							<div>启动时间</div>
							<div class="selsect-box" id="plutime" @click="choosepulTime" style="width: 45vw;"/>{{pulseonTime || '请选择时间'}}</div>
						</div>
						<div class="flex-row mt-10">
							<div class="add-label">是否新报故障</div>
							<div class="flex-row">
								是 <input v-model="isNewFault" type="radio" name="hv" value="1" style="margin: 0 5px;" />
								否 <input v-model="isNewFault" type="radio" name="hv" value="2" style="margin: 0 5px;">
							</div>
						</div>
						<div class="flex-row mt-10">
							<div>&ensp;&ensp;&ensp;&ensp;故障原因</div>
							<textarea  v-model="cause" maxlength="600"></textarea>
						</div>
						<div class="flex-row mt-10">
							<div>故障处理进度</div>
							<textarea  v-model="dealProgress" maxlength="600"></textarea>
						</div>
					</div>
					<div class="mt-10">
						<div>损失信息</div>
						<div class="mt-10">
							<div class="flex-row">
								<div>故障停机时长(h)</div>
								<input id="left_ipt" style="width: 30vw;" placeholder="请输入"  v-model="stopDuration" maxlength="60"/>
							</div>
							<div class="flex-row mt-10">
								<div>故障电量(万kwh)</div>
								<input style="width: 30vw;" id="left_ipt" placeholder="请输入"  v-model="lostPower" maxlength="60"/>
							</div>
							<div class="flex-row mt-10">
								<div>单台故障电量合计(万kwh)</div>
								<input style="width: 30vw;" id="left_ipt" placeholder="请输入"  v-model="oneLostPower" maxlength="60"/>
							</div>
							<div class="flex-row mt-10">
								<div>非限电电故障时长</div>
								<input style="width: 30vw;" id="left_ipt" placeholder="请输入"  v-model="unlimitDuration" maxlength="60"/>
							</div>
						</div>
					</div>
					
					<div class="pop-bottom">
						<div @tap="addList" v-if="!isEdit && !islook">保存</div>
						<div @tap="update" v-if="isEdit && !islook">确认</div>
						<div class="" @tap="showAddform = false">取消</div>
					</div>
				</div>
			</div>
			<!-- <div class="flex-between list-head">
				<div class="flex-row" style="font-weight: bold;">
					<div class="icon"></div>
					流程日志
				</div>
			</div>
			<processlog :processlogid='workId'></processlog> -->
			<div style="height: 60px;">
			</div>
		</div>
		<script src="../../../../js/mui.min.js"></script>
		<script src="../../../../js/vue.js"></script>
		<script src="../../static/js/neiosCommon.js"></script>  <!--公共js页面必需-->
		<script src="../../static/components/personSelect.js"></script>
		<!--人员查询组件-->
		<script type="text/javascript" src="../../static/js/neiosRequst.js"></script>
		<script type="text/javascript" src="../../../../js/jquery-3.2.1.min.js"></script>
		<script src="../../static/components/processLog.js"></script>  <!--流程日志-->
		<script src="../../../../js/mui.picker.js" type="text/javascript" charset="utf-8"></script>
		<script src="../../../../js/mui.poppicker.js"></script>
		<script src="../../../../js/mui.picker.min.js"></script>
		<script src="../../../../js/mui.dtpicker.js"></script>
		<script src="./photFarmRecord.js"></script>
	</body>

</html>
